package entity

import ()

type Order struct {
	Id int64 `gorm:"column:id;type:BIGINT;primary_key" json:"id"`

	EbikeTypeId int64 `gorm:"column:ebike_type_id;type:BIGINT" json:"ebike_type_id"`

	EbikeId int64 `gorm:"column:ebike_id;type:BIGINT" json:"ebike_id"`

	UserId int64 `gorm:"column:user_id;type:BIGINT" json:"user_id"`

	Price int64 `gorm:"column:price;type:BIGINT" json:"price"`

	OrderNo string `gorm:"column:order_no;type:VARCHAR(255)" json:"order_no"`

	StoreId int64 `gorm:"column:store_id;type:BIGINT" json:"store_id"`

	StoreName string `gorm:"column:store_name;type:VARCHAR(255)" json:"store_name"`

	AreaId int64 `gorm:"column:area_id;type:BIGINT" json:"area_id"`

	AreaName string `gorm:"column:area_name;type:VARCHAR(255)" json:"area_name"`

	Status int `gorm:"column:status;type:TINYINT" json:"status"`

	CreatedAt int64 `gorm:"column:created_at;type:BIGINT" json:"created_at"`

	UpdatedAt int64 `gorm:"column:updated_at;type:BIGINT" json:"updated_at"`
}

func (a *Order) TableName() string {
	return "orders"
}
